package com.geepi.soundcloud.controller;

import java.io.File;
import java.io.IOException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.multipart.MultipartFile;



@Controller
public class FileController {	
    private static Logger logger = LoggerFactory.getLogger(FileController.class);	
    @RequestMapping("/HTTP")
    public String handleFileUpload(MultipartFile file) throws IOException {
        String realPath = "/home/liaoyong/filesystem/";
        file.transferTo(new File(realPath + file.getOriginalFilename()));
        return "success";
    }
}
